import Vue from 'vue'
import Vuex from 'Vuex'
Vue.use(Vuex)

const store = new Vuex.Store({
	state: {
		sidemenuShow: false,
		location: '*',
		weather: null
	},
	mutations: {
		openSidemenu (state, value) {
			state.sidemenuShow = value
		},
		setLocation (state, city) {
			state.location = city
		},
		weather (state, data) {
			state.weather = data
		}
	}
})

export default store